1. Field of the Invention
The present invention is directed to a system that uses multiple levels of costs for a pathfinding computation.
2. Description of the Related Art
Computers have revolutionized the idea of modeling systems for enhanced study and use of the systems. One example is the modeling of a system as a network. A network is defmed in its most general sense as something that includes a number of paths that interconnect or branch out. Many systems that involve decisions can be modeled as a network. For example, a manufacturing process or a system of providing medical treatment can be modeled as a network of decision points and actions between decision points. This network can be represented in electronic form and stored on a processor readable storage medium so that software can be created for using the network model to study or use the system.
One example of a useful network that can be stored in electronic form is the electronic map, which includes geographically referenced electronic data quantifying a physical, social or economic system. The range of information included in electronic maps is unlimited; for example, electronic maps could include distances between elements, travel time, lot numbers, tax information, tourist information, processing time, waiting time, etc. Additionally, storing a map as a file on a computer allows for unlimited software applications to manipulate that data.
One advantage of the electronic map is that it can store and determine costs associated with various portions of a map. A cost is a variable that can be minimized or maximized. Note that the costs are not necessarily monetary costs. Rather a cost is something to be minimized or maximized. Typically costs are represented as integers. Sometimes costs can be represented as real numbers. Examples of costs include time, distance, tolls paid, ease of turning, quality of scenery, etc.
Electronic maps, as well as other networks, can also be used for pathfinding, which is a method for computing a route between an origin and a destination. Some systems compute recommended routes and guide the driver by highlighting the recommended route on a map display, or by giving turn-by-turn directions, or both.
When a pathfinding system is computing a recommended route to a destination, it does so by finding the most desirable route according to certain specified criteria. These criteria may be specified by the driver, or may be set as defaults at the time of manufacture. Often, a system will be used to find a path that minimizes (or maximizes) some cost, for example, driving time. One feature that is useful to users of pathfinding systems is the ability to avoid certain elements in the electronic map. A user may want to avoid certain types of roads, turns, intersections, etc. For example, in certain geographic regions, there exist free roads and toll roads. A user may want to find a path that avoids toll roads even if it means longer driving time. Alternatively, a user may also want to avoid use of ferries, tunnels or bridges, etc. In the past, this has been accomplished by making the cost per unit distance of the undesirable road (or other element in the map) very high. That way, the undesirable road (or element) will be used to build a path only when it is sufficiently expensive to avoid it.
The technique of making undesirable elements of an electronic map very expensive has not proven to be an effective means for avoiding the use of the undesirable element. First, making a road segment expensive does not guarantee that the undesirable road will be avoided if possible. That particular type of road may still be chosen in order to avoid a more expensive route on different roads. Second, the prior art technique for avoiding undesirable roads will not guarantee that if a path requires travel on an undesirable road, that the travel on the undesirable road be minimized. Finally, previous attempts to use very large integers to represent an expensive cost can cause an overflow in many computers. Similarly, using a large real number can lead to loss of significance.
Therefore, a system is needed that can compute a path using an electronic map or other network that can attempt to avoid certain categories of elements of the electronic map or other network.